Version

GetTokens(SnapshotSpan,Func<Token,Boolean>,Boolean,Boolean) Method

Returns a object that can enumerate Infragistics.Documents.Parsing.Tokens.
Syntax
'Declaration
 
Public Overloads Function GetTokens( _
   ByVal span As SnapshotSpan, _
   Optional ByVal filter As Func(Of Token,Boolean), _
   Optional ByVal enumerateBackwards As Boolean, _
   Optional ByVal splitMultilineTokensByLine As Boolean _
) As IEnumerable(Of Token)

Parameters

span
The span of text to restrict the token enumeration.
filter
A function that can decide which tokens get returned from the enumerator.
enumerateBackwards
True to enumerate backwards from the end of the span to the beginning of the span.
splitMultilineTokensByLine
Indicates whether multiline tokens should be split so no token returned spans multiple line.

Return Value

A forward or backward enumerator of Tokens
Remarks

Note: even though the snapshot is thread-safe, the enumerator is not. Therefore this method should be called on the same thread that is using it (i.e. each thread accessing an enumerator should create its own). Trying to access the properties and methods of an enumerator created on another thread will raise an InvalidOperationException.

Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also